import tkinter as tk
from tkinter import *
def kk():
    print("我被点击了")
    gu=tk.Tk()
    gu.mainloop()

class gui():
    def __init__(self,win):
        self.win=win
    def setinit(self):
        self.win.title("清理工具")              #标题
        self.win.geometry("275x150+800+200")# 窗口大小及出现位置
        self.button=Button(self.win,text="删除",command=kk,activeforeground="red",width="20")   #按钮
        self.button.pack()
        self.button1 = Button(self.win, text="查找", command=kk, activeforeground="red",width="20")  # 按钮
        self.button1.pack()
        self.button2 = Button(self.win, text="移动", command=kk, activeforeground="red",width="20")  # 按钮
        self.button2.pack()

windows=tk.Tk()     #实例化
init=gui(windows)
init.setinit()      #调用函数
windows.mainloop()

